/**
 * @file PwmLedByObject.ino
 * @author JacobFang (1570468006@qq.com)
 * @brief 
 * @version 1.0
 * @date 2022-02-13
 * 
 * @copyright Copyright (c) 2022
 * 
 */
#include "myLed.h"

PwmLed myPwmLed;

/**
 * @brief 系统初始化
 *
 */
void setup()
{
  Serial.begin(9600); //配置波特率
  
  myPwmLed.setLedPin(3);
  int myPwmLedPin = myPwmLed.getLedPin();
  Serial.print("int myPwmLedPin = ");
  Serial.println(myPwmLedPin);
}

/**
 * @brief 主函数
 *
 */
void loop()
{
  for(int i = 0; i < 255; i++)
  {
    myPwmLed.on(i);
    Serial.print("myPwmLed.getPwmVal() == ");
    Serial.println(myPwmLed.getPwmVal());
    delay(10);
  }

}
